package org.lx.nursing.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.PageHelper;
import org.lx.nursing.domain.NursingProject;
import org.lx.nursing.dto.OrderPageDto;
import org.lx.nursing.mapper.NursingProjectMapper;
import org.lx.nursing.service.MemberOrdersProjectService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class MemberOrdersProjectServiceImpl extends ServiceImpl<NursingProjectMapper, NursingProject> implements MemberOrdersProjectService {

    @Override
    public List<NursingProject> getByPage(OrderPageDto orderPageDto) {
        PageHelper.startPage(orderPageDto.getPageNum(), orderPageDto.getPageSize());
        NursingProject nursingProject = new NursingProject();
        nursingProject.setName(orderPageDto.getName());
        return baseMapper.selectNursingProjectList(nursingProject);
    }
}
